package com.jqkb.service;

import okhttp3.ResponseBody;
import retrofit2.Call;
import retrofit2.http.Field;
import retrofit2.http.FormUrlEncoded;
import retrofit2.http.GET;
import retrofit2.http.POST;

public interface UserService {

    @POST("user/login.json")
    @FormUrlEncoded
    Call<ResponseBody> login(
            @Field("username") String username,
            @Field("password") String password);

    @POST("user/listReportingUser.json")
    Call<ResponseBody> listReportingUser();

    /**
     * 修改密码
     */
    @POST("/user/changePassword.json")
    @FormUrlEncoded
    Call<ResponseBody> changePassword(
            @Field("oldPassword") String oldPassword,
            @Field("password") String password
    );

    /**
     * 退出登录
     */
    @GET("/user/exit.json")
    Call<ResponseBody> exit();

}
